package com.weipai.springboot.module.mapper;

import com.weipai.springboot.model.CustomerAddress;
import com.weipai.springboot.model.api.Response;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface CustomerAddressMapper {
    int deleteByPrimaryKey(String addressId);

    int insert(CustomerAddress record);

    int insertSelective(CustomerAddress record);

    CustomerAddress selectByPrimaryKey(String addressId);

    int updateByPrimaryKeySelective(CustomerAddress record);

    int updateByPrimaryKey(CustomerAddress record);

    //获取用户的收货地址
    List<CustomerAddress> getAddressByCustomerId(String id);

    //获取收货地址详细信息
    CustomerAddress getAddressInfoById(@Param("addressId") String id);

    //验证是否有默认地址
    CustomerAddress varCustomerAddress(String customerId);
}